<?php
/**
{
    "teacherId": "INT //老师ID@search; ",
    "teacherName": "VARCHAR //老师名@search; ",
    "courseMainId": "INT //课程主类@foreign::tbl_course_main; @search; @noList; ",
    "courseSub": "INT //课程子类@foreign::tbl_course_sub; @search; @noList; ",
    "courseName": "VARCHAR //科目@noView; @noList; ",
    "focusCount": "INT //关注数@noload; @noList; @noView; ",
    "likeCount": "INT //点赞数@noLoad; @noList; @noView; ",
    "finalScore": "FLOAT //综合评分@noLoad; @noList; @noView; ",
    "schoolScore": "FLOAT //机构得分@noLoad; @noList; @noView; ",
    "effectScore": "FLOAT //效果满意度@noLoad; @noList; @noView; ",
    "serviceScore": "FLOAT //老师评分@noLoad; @noList; @noView; ",
    "scoreCount": "INT //评分数@noLoad; @noList; @noView; ",
    "teacherTypeId": "INT //老师类别@foreign::tbl_teacher_type; @noList; ",
    "teacherImgId": "INT //封面照片@foreign::tbl_image_file; @noList; ",
    "uploadImg": "VARCHAR //教师图片@image; @noList; ",
    "years": "TINYINT //教龄@noList; @noView; ",
    "teacherYear": "VARCHAR //教龄@noList; ",
    "subjectId": "INT //教学方向@noList; ",
    "bornYear": "YEAR //出生年@noList; ",
    "sex": "TINYINT //性别<br>1男2女0未知@status; 0::未知; 1::男; 2::女; ",
    "nationId": "INT //国籍@foreign::tbl_nation; ",
    "hometown": "VARCHAR //祖籍@json; @noList; ",
    "homeProvinceId": "INT //祖籍省份@foreign::tbl_province; @noload; @noList; ",
    "homeCityId": "INT //城市@foreign::tbl_city; @noList; ",
    "schoolId": "INT //机构@foreign::tbl_school; @search; ",
    "provinceId": "INT //省@foreign::tbl_province; @noList; ",
    "cityIdOk": "INT //城市@foreign::tbl_city; ",
    "districeId": "INT //区注意拼写错了@foreign::tbl_district; @noList; ",
    "status": "TINYINT //状态@status; 0::待审核; 2::下线; 3::审核通过::@admin; 4::审核不通过::@admin; 88::删除; @noLoad; @search; ",
    "created": "DATETIME //创建日期@noList; ",
    "uid": "INT //上报人@foreign::tbl_user; @noload; @noList; @search; ",
    "teacherAdminUid": "INT //教师管理员@foreign::tbl_user; @search; @noLoad; ",
    "ip": "VARCHAR //录入者ip@noLoad; @hide; @delete; @noList; ",
    "sort": "INT //排序@noList; ",
    "want": "INT //想学人数@noLoad; @noList; @noView; ",
    "learned": "INT //学过人数@noLoad; @noList; @noView; ",
    "lat": "DECIMAL //纬度@noList; @delete; @noLoad; @noView; ",
    "lng": "DECIMAL //经度@noList; @delete; @noLoad; @noView; ",
    "geo": "VARCHAR //geohash@noList; @delete; @noLoad; @noView; ",
    "summary": "TEXT //简介@noList; "
}
 */

class Teacher extends Base
{
    
	public $teacherId= '';//老师ID@search;
	public $teacherName= NULL;//老师名@search;
	public $courseMainId= "0";//课程主类@foreign::tbl_course_main;@search;@noList;
	public $courseSub= "0";//课程子类@foreign::tbl_course_sub;@search;@noList;
	public $courseName= NULL;//科目@noView;@noList;
	public $focusCount= "0";//关注数@noload;@noList;@noView;
	public $likeCount= "0";//点赞数@noLoad;@noList;@noView;
	public $finalScore= "0";//综合评分@noLoad;@noList;@noView;
	public $schoolScore= "0";//机构得分@noLoad;@noList;@noView;
	public $effectScore= "0";//效果满意度@noLoad;@noList;@noView;
	public $serviceScore= "0";//老师评分@noLoad;@noList;@noView;
	public $scoreCount= "0";//评分数@noLoad;@noList;@noView;
	public $teacherTypeId= "0";//老师类别@foreign::tbl_teacher_type;@noList;
	public $teacherImgId= "0";//封面照片@foreign::tbl_image_file;@noList;
	public $uploadImg= NULL;//教师图片@image;@noList;
	public $years= "0";//教龄@noList;@noView;
	public $teacherYear= NULL;//教龄@noList;
	public $subjectId= "0";//教学方向@noList;
	public $bornYear= NULL;//出生年@noList;
	public $sex= "0";//性别<br>1男2女0未知@status;0::未知;1::男;2::女;
	public $nationId= "0";//国籍@foreign::tbl_nation;
	public $hometown= [];//祖籍@json;@noList;
	public $homeProvinceId= "0";//祖籍省份@foreign::tbl_province;@noload;@noList;
	public $homeCityId= "0";//城市@foreign::tbl_city;@noList;
	public $schoolId= "0";//机构@foreign::tbl_school;@search;
	public $provinceId= "0";//省@foreign::tbl_province;@noList;
	public $cityIdOk= "0";//城市@foreign::tbl_city;
	public $districeId= "0";//区注意拼写错了@foreign::tbl_district;@noList;
	public $status= "0";//状态@status;0::待审核;2::下线;3::审核通过::@admin;4::审核不通过::@admin;88::删除;@noLoad;@search;
	public $created= 'CURRENT_TIMESTAMP';//创建日期@noList;
	public $uid= "0";//上报人@foreign::tbl_user;@noload;@noList;@search;
	public $teacherAdminUid= "0";//教师管理员@foreign::tbl_user;@search;@noLoad;
	public $ip= NULL;//录入者ip@noLoad;@hide;@delete;@noList;
	public $sort= "0";//排序@noList;
	public $want= "0";//想学人数@noLoad;@noList;@noView;
	public $learned= "0";//学过人数@noLoad;@noList;@noView;
	public $lat= "0.0000000";//纬度@noList;@delete;@noLoad;@noView;
	public $lng= "0.0000000";//经度@noList;@delete;@noLoad;@noView;
	public $geo= NULL;//geohash@noList;@delete;@noLoad;@noView;
	public $summary= '';//简介@noList;

    public $isDbData = false;

    public function __construct()
    {
        parent::__construct();
    }


    public function __get($name) {
        return $this->$name;
    }

    public function __set($name, $value) {
        if(!$this->isDbData){
            if(!in_array($name,$this->loadedFiled))$this->loadedFiled[] = $name;
        }

        $this->$name=$value;
        $this->arr[$name] = $value;
    }

    public  function table()
    {
        return 'tbl_teacher';
    }
    
    public  function key(){
        return 'teacherId';
    }


    
    public static  function hideField()
    {
        return array (  0 => 'ip',);
    }
            
    public static  function skipField()
    {
        return [];
    }
            
    public static  function noViewField()
    {
        return array (  0 => 'courseName',  1 => 'focusCount',  2 => 'likeCount',  3 => 'finalScore',  4 => 'schoolScore',  5 => 'effectScore',  6 => 'serviceScore',  7 => 'scoreCount',  8 => 'years',  9 => 'want',  10 => 'learned',  11 => 'lat',  12 => 'lng',  13 => 'geo',);
    }
            
    public static  function jsonField()
    {
        return array (  0 => 'hometown',);
    }
            
    public static  function noLoadField()
    {
        return array (  0 => 'likeCount',  1 => 'finalScore',  2 => 'schoolScore',  3 => 'effectScore',  4 => 'serviceScore',  5 => 'scoreCount',  6 => 'status',  7 => 'teacherAdminUid',  8 => 'ip',  9 => 'want',  10 => 'learned',  11 => 'lat',  12 => 'lng',  13 => 'geo',);
    }
            
    public static  function deleteField()
    {
        return array (  0 => 'ip',  1 => 'lat',  2 => 'lng',  3 => 'geo',);
    }
            
    public function className()
    {
        return 'Teacher';
    }
    
    public  function field()
    {
        return array (  'teacherId' =>   array (    0 => 'INT',    1 => 11,    2 => '老师ID@search;',  ),  'teacherName' =>   array (    0 => 'VARCHAR',    1 => 50,    2 => '老师名@search;',  ),  'courseMainId' =>   array (    0 => 'INT',    1 => 11,    2 => '课程主类@foreign::tbl_course_main;@search;@noList;',  ),  'courseSub' =>   array (    0 => 'INT',    1 => 11,    2 => '课程子类@foreign::tbl_course_sub;@search;@noList;',  ),  'courseName' =>   array (    0 => 'VARCHAR',    1 => 255,    2 => '科目@noView;@noList;',  ),  'focusCount' =>   array (    0 => 'INT',    1 => 11,    2 => '关注数@noload;@noList;@noView;',  ),  'likeCount' =>   array (    0 => 'INT',    1 => 11,    2 => '点赞数@noLoad;@noList;@noView;',  ),  'finalScore' =>   array (    0 => 'FLOAT',    1 => 0,    2 => '综合评分@noLoad;@noList;@noView;',  ),  'schoolScore' =>   array (    0 => 'FLOAT',    1 => 0,    2 => '机构得分@noLoad;@noList;@noView;',  ),  'effectScore' =>   array (    0 => 'FLOAT',    1 => 0,    2 => '效果满意度@noLoad;@noList;@noView;',  ),  'serviceScore' =>   array (    0 => 'FLOAT',    1 => 0,    2 => '老师评分@noLoad;@noList;@noView;',  ),  'scoreCount' =>   array (    0 => 'INT',    1 => 11,    2 => '评分数@noLoad;@noList;@noView;',  ),  'teacherTypeId' =>   array (    0 => 'INT',    1 => 11,    2 => '老师类别@foreign::tbl_teacher_type;@noList;',  ),  'teacherImgId' =>   array (    0 => 'INT',    1 => 11,    2 => '封面照片@foreign::tbl_image_file;@noList;',  ),  'uploadImg' =>   array (    0 => 'VARCHAR',    1 => 512,    2 => '教师图片@image;@noList;',  ),  'years' =>   array (    0 => 'TINYINT',    1 => 4,    2 => '教龄@noList;@noView;',  ),  'teacherYear' =>   array (    0 => 'VARCHAR',    1 => 100,    2 => '教龄@noList;',  ),  'subjectId' =>   array (    0 => 'INT',    1 => 11,    2 => '教学方向@noList;',  ),  'bornYear' =>   array (    0 => 'YEAR',    1 => 4,    2 => '出生年@noList;',  ),  'sex' =>   array (    0 => 'TINYINT',    1 => 4,    2 => '性别<br>1男2女0未知@status;0::未知;1::男;2::女;',  ),  'nationId' =>   array (    0 => 'INT',    1 => 11,    2 => '国籍@foreign::tbl_nation;',  ),  'hometown' =>   array (    0 => 'VARCHAR',    1 => 512,    2 => '祖籍@json;@noList;',  ),  'homeProvinceId' =>   array (    0 => 'INT',    1 => 11,    2 => '祖籍省份@foreign::tbl_province;@noload;@noList;',  ),  'homeCityId' =>   array (    0 => 'INT',    1 => 11,    2 => '城市@foreign::tbl_city;@noList;',  ),  'schoolId' =>   array (    0 => 'INT',    1 => 11,    2 => '机构@foreign::tbl_school;@search;',  ),  'provinceId' =>   array (    0 => 'INT',    1 => 11,    2 => '省@foreign::tbl_province;@noList;',  ),  'cityIdOk' =>   array (    0 => 'INT',    1 => 11,    2 => '城市@foreign::tbl_city;',  ),  'districeId' =>   array (    0 => 'INT',    1 => 11,    2 => '区注意拼写错了@foreign::tbl_district;@noList;',  ),  'status' =>   array (    0 => 'TINYINT',    1 => 4,    2 => '状态@status;0::待审核;2::下线;3::审核通过::@admin;4::审核不通过::@admin;88::删除;@noLoad;@search;',  ),  'created' =>   array (    0 => 'DATETIME',    1 => 0,    2 => '创建日期@noList;',  ),  'uid' =>   array (    0 => 'INT',    1 => 11,    2 => '上报人@foreign::tbl_user;@noload;@noList;@search;',  ),  'teacherAdminUid' =>   array (    0 => 'INT',    1 => 11,    2 => '教师管理员@foreign::tbl_user;@search;@noLoad;',  ),  'ip' =>   array (    0 => 'VARCHAR',    1 => 15,    2 => '录入者ip@noLoad;@hide;@delete;@noList;',  ),  'sort' =>   array (    0 => 'INT',    1 => 11,    2 => '排序@noList;',  ),  'want' =>   array (    0 => 'INT',    1 => 11,    2 => '想学人数@noLoad;@noList;@noView;',  ),  'learned' =>   array (    0 => 'INT',    1 => 11,    2 => '学过人数@noLoad;@noList;@noView;',  ),  'lat' =>   array (    0 => 'DECIMAL',    1 => 10,    2 => '纬度@noList;@delete;@noLoad;@noView;',  ),  'lng' =>   array (    0 => 'DECIMAL',    1 => 10,    2 => '经度@noList;@delete;@noLoad;@noView;',  ),  'geo' =>   array (    0 => 'VARCHAR',    1 => 30,    2 => 'geohash@noList;@delete;@noLoad;@noView;',  ),  'summary' =>   array (    0 => 'TEXT',    1 => 0,    2 => '简介@noList;',  ),);
    }


}